<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateOpenCitiesTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('open_cities', function (Blueprint $table) {
            $table->increments('id');
            $table->string('key', 50)->comment('城市码');
            $table->string('remark', 100)->comment('备注');
            $table->integer('default')->default(0)->comment('默认城市');

            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('open_cities');
    }
}
